//
//  YCPersonInfoViewController.m
//  DemoYTX
//
//  Created by 唐可雄 on 16/7/13.
//  Copyright © 2016年 swustyc. All rights reserved.
//

#import "YCPersonInfoViewController.h"

@interface YCPersonInfoViewController () {
    NSDate *_birthday;
}

@end

@implementation YCPersonInfoViewController

#pragma mark - Life Cycle

- (void)viewDidLoad {
    [super viewDidLoad];
    
    [self configBirthdayBtn];
    [self configSignatureTxtView];
}

#pragma mark - View Config

/// 配置生日按钮
- (void)configBirthdayBtn {
    if (_birthday == nil) {
        [self.birthdayBtn setTitle:@"请选择生日" forState:UIControlStateNormal];
        [self.birthdayBtn setTitleColor:[UIColor lightGrayColor] forState:UIControlStateNormal];
    } else {
        NSDateFormatter *dateFormatter = [[NSDateFormatter alloc] init];
        dateFormatter.dateFormat = @"YYYY-MM-dd";
        
        [self.birthdayBtn setTitle:[dateFormatter stringFromDate:_birthday] forState:UIControlStateNormal];
        [self.birthdayBtn setTitleColor:[UIColor blackColor] forState:UIControlStateNormal];
    }
}

/// 配置个性签名输入框
- (void)configSignatureTxtView {
    self.signatureTxtView.layer.cornerRadius = 4.f;
    self.signatureTxtView.layer.borderColor = [UIColor lightGrayColor].CGColor;
    self.signatureTxtView.layer.borderWidth = 0.5;
}

#pragma mark - IBAction


@end
